home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.mactech.com 2010
/
ftp.mactech.com.tar
/
ftp.mactech.com
/
thinkref
/
archive
/
THINKPascalUH2.1.sea
/
THINKPas Univ Hdr 2.1
/
Interfaces
/
GXTypes.p
< prev
next >
Wrap
Text File
|
1995-09-12
|
47KB
|
1,838 lines
{ Converted with MPW2TPas Tuesday, September 12, 1995 7:06:53 PM }
{
File: GXTypes.p
Contains: QuickDraw GX object and constant definitions
Version: Technology: Quickdraw GX 1.1
Package: Universal Interfaces 2.1 in “MPW Latest” on ETO #18
Copyright: © 1984-1995 by Apple Computer, Inc.
All rights reserved.
Bugs?: If you find a problem with this file, use the Apple Bug Reporter
stack. Include the file and version information (from above)
in the problem description and send to:
Internet: apple.bugs@applelink.apple.com
AppleLink: APPLE.BUGS
}
UNIT GXTypes;
INTERFACE
{$IFC UNDEFINED __GXTYPES__}
{$SETC __GXTYPES__ := 1}
USES
ConditionalMacros, Types, MixedMode, GXMath;
{ $PUSH}
{ $ALIGN MAC68K}
{ $LibExport+}
{$SETC graphicsTypesIncludes := 1}
TYPE
gxShape = Ptr;
gxStyle = Ptr;
gxInk = Ptr;
gxTransform = Ptr;
gxTag = Ptr;
gxColorSet = Ptr;
gxColorProfile = Ptr;
gxGraphicsClient = Ptr;
gxViewGroup = Ptr;
gxViewPort = Ptr;
gxViewDevice = Ptr;
gxColorSpace = LONGINT;
{ gxShape enumerations }
CONST
gxEmptyType = 1;
gxPointType = 2;
gxLineType = 3;
gxCurveType = 4;
gxRectangleType = 5;
gxPolygonType = 6;
gxPathType = 7;
gxBitmapType = 8;
gxTextType = 9;
gxGlyphType = 10;
gxLayoutType = 11;
gxFullType = 12;
gxPictureType = 13;
TYPE
gxShapeType = LONGINT;
CONST
gxNoFill = 0;
gxOpenFrameFill = 1;
gxFrameFill = gxOpenFrameFill;
gxClosedFrameFill = 2;
gxHollowFill = gxClosedFrameFill;
gxEvenOddFill = 3;
gxSolidFill = gxEvenOddFill;
gxWindingFill = 4;
gxInverseEvenOddFill = 5;
gxInverseSolidFill = gxInverseEvenOddFill;
gxInverseFill = gxInverseEvenOddFill;
gxInverseWindingFill = 6;
TYPE
gxShapeFill = LONGINT;
CONST
gxNoAttributes = 0;
gxDirectShape = $0001;
gxRemoteShape = $0002;
gxCachedShape = $0004;
gxLockedShape = $0008;
gxGroupShape = $0010;
gxMapTransformShape = $0020;
gxUniqueItemsShape = $0040;
gxIgnorePlatformShape = $0080;
gxNoMetricsGridShape = $0100;
gxDiskShape = $0200;
gxMemoryShape = $0400;
TYPE
gxShapeAttribute = LONGINT;
{ gxShape editing enumerations }
CONST
gxBreakNeitherEdit = 0;
gxBreakLeftEdit = $0001;
gxBreakRightEdit = $0002;
gxRemoveDuplicatePointsEdit = $0004;
{ if the new first (or last) point exactly matches the point before it in }
{ the same contour, then remove it) }
TYPE
gxEditShapeFlag = LONGINT;
CONST
gxSelectToEnd = -1;
gxAnyNumber = 1;
gxSetToNil = -1;
gxCounterclockwiseDirection = 0;
gxClockwiseDirection = 1;
TYPE
gxContourDirection = LONGINT;
{ gxShape structures }
{ The type 'gxPoint' is defined in "GXMath.h" }
gxLine = RECORD
first: gxPoint;
last: gxPoint;
END;
gxCurve = RECORD
first: gxPoint;
control: gxPoint;
last: gxPoint;
END;
gxRectangle = RECORD
left: Fixed;
top: Fixed;
right: Fixed;
bottom: Fixed;
END;
gxPolygon = RECORD
vectors: LONGINT;
vector: ARRAY [0..0] OF gxPoint;
END;
gxPolygons = RECORD
contours: LONGINT;
contour: ARRAY [0..0] OF gxPolygon;
END;
gxPath = RECORD
vectors: LONGINT;
controlBits: ARRAY [0..0] OF LONGINT;
vector: ARRAY [0..0] OF gxPoint;
END;
gxPaths = RECORD
contours: LONGINT;
contour: ARRAY [0..0] OF gxPath;
END;
gxBitmap = RECORD
image: ^CHAR; { pointer to pixels }
width: LONGINT; { width in pixels }
height: LONGINT; { height in pixels }
rowBytes: LONGINT; { width in bytes }
pixelSize: LONGINT; { physical bits per pixel }
space: gxColorSpace;
colorSet: gxColorSet;
profile: gxColorProfile;
END;
gxLongRectangle = RECORD
left: LONGINT;
top: LONGINT;
right: LONGINT;
bottom: LONGINT;
END;
{ gxStyle enumerations }
CONST
gxCenterFrameStyle = 0;
gxSourceGridStyle = $0001;
gxDeviceGridStyle = $0002;
gxInsideFrameStyle = $0004;
gxOutsideFrameStyle = $0008;
gxAutoInsetStyle = $0010;
TYPE
gxStyleAttribute = LONGINT;
CONST
gxBendDash = $0001;
gxBreakDash = $0002;
gxClipDash = $0004;
gxLevelDash = $0008;
gxAutoAdvanceDash = $0010;
TYPE
gxDashAttribute = LONGINT;
CONST
gxPortAlignPattern = $0001;
gxPortMapPattern = $0002;
TYPE
gxPatternAttribute = LONGINT;
CONST
gxSharpJoin = $0000;
gxCurveJoin = $0001;
gxLevelJoin = $0002;
TYPE
gxJoinAttribute = LONGINT;
CONST
gxLevelStartCap = $0001;
gxLevelEndCap = $0002;
TYPE
gxCapAttribute = LONGINT;
CONST
gxAutoAdvanceText = $0001;
gxNoContourGridText = $0002;
gxNoMetricsGridText = $0004;
gxAnchorPointsText = $0008;
gxVerticalText = $0010;
gxNoOpticalScaleText = $0020;
TYPE
gxTextAttribute = LONGINT;
CONST
gxLeftJustify = 0;
gxCenterJustify = $20000000;
gxRightJustify = $40000000;
gxFillJustify = -1;
gxUnderlineAdvanceLayer = $0001; { a gxLine is drawn through the advances }
gxSkipWhiteSpaceLayer = $0002; { except characters describing white space }
gxUnderlineIntervalLayer = $0004; { (+ gxStringLayer) a gxLine is drawn through the gaps between advances }
gxUnderlineContinuationLayer = $0008; { (+ gxStringLayer) join this underline with another face }
gxWhiteLayer = $0010; { the layer draws to white instead of black }
gxClipLayer = $0020; { the characters define a clip }
gxStringLayer = $0040; { all characters in run are combined }
TYPE
gxLayerFlag = LONGINT;
{ gxStyle structures }
gxFaceLayer = RECORD
outlineFill: gxShapeFill; { outline framed or filled }
flags: gxLayerFlag; { various additional effects }
outlineStyle: gxStyle; { outline }
outlineTransform: gxTransform; { italic, condense, extend }
boldOutset: gxPoint; { bold }
END;
gxTextFace = RECORD
faceLayers: LONGINT; { layer to implement shadow }
advanceMapping: gxMapping; { algorithmic change to advance width }
faceLayer: ARRAY [0..0] OF gxFaceLayer; { zero or more face layers describing the face }
END;
gxJoinRecord = RECORD
attributes: gxJoinAttribute;
join: gxShape;
miter: Fixed;
END;
gxDashRecord = RECORD
attributes: gxDashAttribute;
dash: gxShape; { similar to pattern, except rotated to gxLine slope }
advance: Fixed; { specifies repeating frequency of dash }
phase: Fract; { specifies offset into the gxPath to start dashing }
scale: Fixed; { specifies height of dash to be mapped to penWidth }
END;
gxPatternRecord = RECORD
attributes: gxPatternAttribute;
pattern: gxShape;
u: gxPoint;
v: gxPoint;
END;
gxCapRecord = RECORD
attributes: gxCapAttribute;
startCap: gxShape;
endCap: gxShape;
END;
{ gxInk enumerations }
CONST
gxPortAlignDitherInk = $0001;
gxForceDitherInk = $0002;
gxSuppressDitherInk = $0004;
gxSuppressHalftoneInk = $0008;
TYPE
gxInkAttribute = LONGINT;
CONST
gxNoMode = 0;
gxCopyMode = 1;
gxAddMode = 2;
gxBlendMode = 3;
gxMigrateMode = 4;
gxMinimumMode = 5;
gxMaximumMode = 6;
gxHighlightMode = 7;
gxAndMode = 8;
gxOrMode = 9;
gxXorMode = 10;
gxRampAndMode = 11;
gxRampOrMode = 12;
gxRampXorMode = 13;
gxOverMode = 14; { Alpha channel modes }
gxAtopMode = 15; { Note: In England = Beta channel modes }
gxExcludeMode = 16;
gxFadeMode = 17;
TYPE
gxComponentMode = SInt8;
CONST
gxRejectSourceTransfer = $0001; { at least one component must be out of range }
gxRejectDeviceTransfer = $0002; { at least one component must be out of range }
gxSingleComponentTransfer = $0004; { duplicate gxTransferComponent[0] for all components in transfer }
TYPE
gxTransferFlag = LONGINT;
CONST
gxOverResultComponent = $01; { & result gxColor with 0xFFFF before clamping }
gxReverseComponent = $02; { reverse source and device before moding }
TYPE
gxComponentFlag = SInt8;
gxTransferComponent = RECORD
mode: gxComponentMode; { how the component is operated upon }
flags: gxComponentFlag; { flags for each component }
sourceMinimum: gxColorValue;
sourceMaximum: gxColorValue; { input filter range }
deviceMinimum: gxColorValue;
deviceMaximum: gxColorValue; { output filter range }
clampMinimum: gxColorValue;
clampMaximum: gxColorValue; { output clamping range }
operand: gxColorValue; { ratio for blend, step for migrate, gxColor for highlight }
END;
gxTransferMode = RECORD
space: gxColorSpace; { the gxColor-space the transfer mode is to operate in }
colorSet: gxColorSet;
profile: gxColorProfile;
sourceMatrix: ARRAY [0..4,0..3] OF Fixed;
deviceMatrix: ARRAY [0..4,0..3] OF Fixed;
resultMatrix: ARRAY [0..4,0..3] OF Fixed;
flags: gxTransferFlag;
component: ARRAY [0..3] OF gxTransferComponent; { how each component is operated upon }
END;
{ gxColor space enumerations }
CONST
gxNoColorPacking = $0000; { 16 bits per channel }
gxAlphaSpace = $0080; { space includes alpha channel }
gxWord5ColorPacking = $0500; { 5 bits per channel, right-justified }
gxLong8ColorPacking = $0800; { 8 bits per channel, right-justified }
gxLong10ColorPacking = $0a00; { 10 bits per channel, right-justified }
gxAlphaFirstPacking = $1000; { alpha channel is the first field in the packed space }
gxNoSpace = 0;
gxRGBSpace = 1;
gxCMYKSpace = 2;
gxHSVSpace = 3;
gxHLSSpace = 4;
gxYXYSpace = 5;
gxXYZSpace = 6;
gxLUVSpace = 7;
gxLABSpace = 8;
gxYIQSpace = 9;
gxNTSCSpace = gxYIQSpace;
gxPALSpace = gxYIQSpace;
gxGraySpace = 10;
gxIndexedSpace = 11;
gxRGBASpace = $81;
gxGrayASpace = $8A;
gxRGB16Space = $501;
gxRGB32Space = $801;
gxARGB32Space = $1881;
gxCMYK32Space = $802;
gxHSV32Space = $A03;
gxHLS32Space = $A04;
gxYXY32Space = $A05;
gxXYZ32Space = $A06;
gxLUV32Space = $A07;
gxLAB32Space = $A08;
gxYIQ32Space = $A09;
gxNTSC32Space = gxYIQ32Space;
gxPAL32Space = gxYIQ32Space;
{ gxColor space structures }
TYPE
gxRGBColor = RECORD
red: gxColorValue;
green: gxColorValue;
blue: gxColorValue;
END;
gxRGBAColor = RECORD
red: gxColorValue;
green: gxColorValue;
blue: gxColorValue;
alpha: gxColorValue;
END;
gxHSVColor = RECORD
hue: gxColorValue;
saturation: gxColorValue;
value: gxColorValue;
END;
gxHLSColor = RECORD
hue: gxColorValue;
lightness: gxColorValue;
saturation: gxColorValue;
END;
gxCMYKColor = RECORD
cyan: gxColorValue;
magenta: gxColorValue;
yellow: gxColorValue;
black: gxColorValue;
END;
gxXYZColor = RECORD
x: gxColorValue;
y: gxColorValue;
z: gxColorValue;
END;
gxYXYColor = RECORD
capY: gxColorValue;
x: gxColorValue;
y: gxColorValue;
END;
gxLUVColor = RECORD
l: gxColorValue;
u: gxColorValue;
v: gxColorValue;
END;
gxLABColor = RECORD
l: gxColorValue;
a: gxColorValue;
b: gxColorValue;
END;
gxYIQColor = RECORD
y: gxColorValue;
i: gxColorValue;
q: gxColorValue;
END;
gxGrayAColor = RECORD
gray: gxColorValue;
alpha: gxColorValue;
END;
gxColorIndex = LONGINT;
gxIndexedColor = RECORD
index: gxColorIndex;
colorSet: gxColorSet;
END;
gxColor = RECORD
space: gxColorSpace;
profile: gxColorProfile;
CASE INTEGER OF
0: (
cmyk: gxCMYKColor;
);
1: (
rgb: gxRGBColor;
);
2: (
rgba: gxRGBAColor;
);
3: (
hsv: gxHSVColor;
);
4: (
hls: gxHLSColor;
);
5: (
xyz: gxXYZColor;
);
6: (
yxy: gxYXYColor;
);
7: (
luv: gxLUVColor;
);
8: (
lab: gxLABColor;
);
9: (
yiq: gxYIQColor;
);
10: (
gray: gxColorValue;
);
11: (
graya: gxGrayAColor;
);
12: (
pixel16: INTEGER;
);
13: (
pixel32: LONGINT;
);
14: (
indexed: gxIndexedColor;
);
15: (
component: ARRAY [0..3] OF gxColorValue;
);
END;
{ gxColorSet structures }
gxSetColor = RECORD
CASE INTEGER OF
0: (
cmyk: gxCMYKColor;
);
1: (
rgb: gxRGBColor;
);
2: (
rgba: gxRGBAColor;
);
3: (
hsv: gxHSVColor;
);
4: (
hls: gxHLSColor;
);
5: (
xyz: gxXYZColor;
);
6: (
yxy: gxYXYColor;
);
7: (
luv: gxLUVColor;
);
8: (
lab: gxLABColor;
);
9: (
yiq: gxYIQColor;
);
10: (
gray: gxColorValue;
);
11: (
graya: gxGrayAColor;
);
12: (
pixel16: INTEGER;
);
13: (
pixel32: LONGINT;
);
14: (
component: ARRAY [0..3] OF gxColorValue;
);
END;
{ gxTransform enumerations }
{ parts of a gxShape considered in hit testing: }
CONST
gxNoPart = 0; { (in order of evaluation) }
gxBoundsPart = $0001;
gxGeometryPart = $0002;
gxPenPart = $0004;
gxCornerPointPart = $0008;
gxControlPointPart = $0010;
gxEdgePart = $0020;
gxJoinPart = $0040;
gxStartCapPart = $0080;
gxEndCapPart = $0100;
gxDashPart = $0200;
gxPatternPart = $0400;
gxGlyphBoundsPart = gxJoinPart;
gxGlyphFirstPart = gxStartCapPart;
gxGlyphLastPart = gxEndCapPart;
gxSideBearingPart = gxDashPart;
gxAnyPart = $7FF;
TYPE
gxShapePart = LONGINT;
{ gxTransform structures }
gxHitTestInfo = RECORD
what: gxShapePart; { which part of gxShape }
index: LONGINT; { control gxPoint index }
distance: Fixed; { how far from gxPoint or outside of area click was }
{ these fields are only set by GXHitTestPicture }
which: gxShape;
containerPicture: gxShape; { picture which contains gxShape hit }
containerIndex: LONGINT; { the index within that picture }
totalIndex: LONGINT; { the total index within the root picture }
END;
{ gxViewPort enumerations }
CONST
gxGrayPort = $0001;
gxAlwaysGridPort = $0002;
gxEnableMatchPort = $0004;
TYPE
gxPortAttribute = LONGINT;
{ gxViewDevice enumerations }
CONST
gxDirectDevice = $01; { for the device gxBitmap baseAddr pointer }
gxRemoteDevice = $02;
gxInactiveDevice = $04;
TYPE
gxDeviceAttribute = LONGINT;
CONST
gxRoundDot = 1;
gxSpiralDot = 2;
gxSquareDot = 3;
gxLineDot = 4;
gxEllipticDot = 5;
gxTriangleDot = 6;
gxDispersedDot = 7;
gxCustomDot = 8;
TYPE
gxDotType = LONGINT;
{ gxViewPort structures }
CONST
gxNoTint = 0;
gxLuminanceTint = 1; { use the luminance of the gxColor }
gxAverageTint = 2; { add all the components and divide by the number of components }
gxMixtureTint = 3; { find the closest gxColor on the axis between the foreground and background }
gxComponent1Tint = 4; { use the value of the first component of the gxColor }
gxComponent2Tint = 5; { ... etc. }
gxComponent3Tint = 6;
gxComponent4Tint = 7;
TYPE
gxTintType = LONGINT;
gxHalftone = RECORD
angle: Fixed;
frequency: Fixed;
method: gxDotType;
tinting: gxTintType;
dotColor: gxColor;
backgroundColor: gxColor;
tintSpace: gxColorSpace;
END;
gxHalftoneMatrix = RECORD
dpiX: Fixed; { intended resolution }
dpiY: Fixed;
width: LONGINT; { width of matrix (in device pixels) }
height: LONGINT; { height of matrix (in device pixels) }
tileShift: LONGINT; { shift amount (in samples) for rectangular tiling }
samples: ARRAY [0..0] OF INTEGER; { samples from 0..MAX(halftone tintSpace) }
END;
{ gxViewGroup enumerations }
CONST
gxAllViewDevices = 0;
gxScreenViewDevices = 1;
gxOpenReadSpool = 1;
gxOpenWriteSpool = 2;
gxReadSpool = 3;
gxWriteSpool = 4;
gxCloseSpool = 5;
TYPE
gxSpoolCommand = LONGINT;
gxGraphicsOpcode = SInt8;
gxSpoolProcPtr = ProcPtr; { FUNCTION gxSpool(command: gxSpoolCommand; VAR block: gxSpoolBlock): LONGINT; }
gxSpoolUPP = UniversalProcPtr;
gxSpoolBlock = RECORD
spoolProcedure: gxSpoolUPP; { these fields are read only }
buffer: Ptr; { source/destination pointer to data }
bufferSize: LONGINT; { how many bytes for the system to read (flatten) / write (unflatten) }
{ these fields are written to (but are not read from) }
count: LONGINT; { how many bytes for the caller to read (unflatten) /write (flatten) }
operationSize: LONGINT; { operation size (including operand byte) }
operationOffset: LONGINT; { the data offset, if any, within the current operation }
lastTypeOpcode: gxGraphicsOpcode; { type of last created object }
currentOperation: gxGraphicsOpcode; { operation emitted by flatten, or intrepreted by last unflatten }
currentOperand: gxGraphicsOpcode; { e.g., gxTransformTypeOpcode, gxInkTagOpcode }
compressed: SInt8; { unsigned char } { one of: gxTwoBitCompressionValues }
END;
CONST
uppgxSpoolProcInfo = $000003F1; { FUNCTION (4 byte param, 4 byte param): 4 byte result; }
FUNCTION NewgxSpoolProc(userRoutine: gxSpoolProcPtr): gxSpoolUPP;
{$IFC NOT GENERATINGCFM }
INLINE $2E9F;
{$ENDC}
FUNCTION CallgxSpoolProc(command: gxSpoolCommand; VAR block: gxSpoolBlock; userRoutine: gxSpoolUPP): LONGINT;
{$IFC NOT GENERATINGCFM}
INLINE $205F, $4E90;
{$ENDC}
CONST
gxFontListFlatten = $01; { if set, generate a gxTag containing list of each gxFont referenced }
gxFontGlyphsFlatten = $02; { if set, generate a gxTag containing the list of glyphs referenced inside the gxFont }
gxFontVariationsFlatten = $04; { if set, append the gxTag with separate [variation] coordinates }
gxBitmapAliasFlatten = $08; { if set, open bitmap alias files and flatten out their image data }
TYPE
gxFlattenFlag = LONGINT;
{ gxGraphicsClient constants }
CONST
gxGraphicsSystemClient = -1;
gxStaticHeapClient = $0001;
TYPE
gxClientAttribute = LONGINT;
{ graphics patching constants }
CONST
gxOriginalGraphicsFunction = -1;
gxOriginalGraphicsIdentifier = 'grfx';
TYPE
gxBitmapDataSourceAlias = RECORD
fileOffset: LONGINT; { file offset (in bytes) of top-left pixel }
aliasRecordSize: LONGINT; { size of alias record below }
aliasRecord: ARRAY [0..0] OF SInt8; { unsigned char } { the actual alias record data }
END;
CONST
gxBitmapFileAliasTagType = 'bfil';
gxBitmapFileAliasImageValue = 1;
{$SETC fontTypesIncludes := 1}
TYPE
gxFont = ^Ptr;
CONST
gxNoPlatform = 0;
gxNoScript = 0;
gxNoLanguage = 0;
gxNoFontName = 0;
gxGlyphPlatform = -1;
gxUnicodePlatform = 1;
gxMacintoshPlatform = 2;
gxReservedPlatform = 3;
gxMicrosoftPlatform = 4;
gxCustomPlatform = 5;
TYPE
gxFontPlatform = LONGINT;
CONST
gxUnicodeDefaultSemantics = 1;
gxUnicodeV1_1Semantics = 2;
gxISO10646_1993Semantics = 3;
gxRomanScript = 1;
gxJapaneseScript = 2;
gxTraditionalChineseScript = 3;
gxChineseScript = gxTraditionalChineseScript;
gxKoreanScript = 4;
gxArabicScript = 5;
gxHebrewScript = 6;
gxGreekScript = 7;
gxCyrillicScript = 8;
gxRussian = gxCyrillicScript;
gxRSymbolScript = 9;
gxDevanagariScript = 10;
gxGurmukhiScript = 11;
gxGujaratiScript = 12;
gxOriyaScript = 13;
gxBengaliScript = 14;
gxTamilScript = 15;
gxTeluguScript = 16;
gxKannadaScript = 17;
gxMalayalamScript = 18;
gxSinhaleseScript = 19;
gxBurmeseScript = 20;
gxKhmerScript = 21;
gxThaiScript = 22;
gxLaotianScript = 23;
gxGeorgianScript = 24;
gxArmenianScript = 25;
gxSimpleChineseScript = 26;
gxTibetanScript = 27;
gxMongolianScript = 28;
gxGeezScript = 29;
gxEthiopicScript = gxGeezScript;
gxAmharicScript = gxGeezScript;
gxSlavicScript = 30;
gxEastEuropeanRomanScript = gxSlavicScript;
gxVietnameseScript = 31;
gxExtendedArabicScript = 32;
gxSindhiScript = gxExtendedArabicScript;
gxUninterpretedScript = 33;
gxMicrosoftSymbolScript = 1;
gxMicrosoftStandardScript = 2;
gxCustom8BitScript = 1;
gxCustom816BitScript = 2;
gxCustom16BitScript = 3;
TYPE
gxFontScript = LONGINT;
CONST
gxEnglishLanguage = 1;
gxFrenchLanguage = 2;
gxGermanLanguage = 3;
gxItalianLanguage = 4;
gxDutchLanguage = 5;
gxSwedishLanguage = 6;
gxSpanishLanguage = 7;
gxDanishLanguage = 8;
gxPortugueseLanguage = 9;
gxNorwegianLanguage = 10;
gxHebrewLanguage = 11;
gxJapaneseLanguage = 12;
gxArabicLanguage = 13;
gxFinnishLanguage = 14;
gxGreekLanguage = 15;
gxIcelandicLanguage = 16;
gxMalteseLanguage = 17;
gxTurkishLanguage = 18;
gxCroatianLanguage = 19;
gxTradChineseLanguage = 20;
gxUrduLanguage = 21;
gxHindiLanguage = 22;
gxThaiLanguage = 23;
gxKoreanLanguage = 24;
gxLithuanianLanguage = 25;
gxPolishLanguage = 26;
gxHungarianLanguage = 27;
gxEstonianLanguage = 28;
gxLettishLanguage = 29;
gxLatvianLanguage = gxLettishLanguage;
gxSaamiskLanguage = 30;
gxLappishLanguage = gxSaamiskLanguage;
gxFaeroeseLanguage = 31;
gxFarsiLanguage = 32;
gxPersianLanguage = gxFarsiLanguage;
gxRussianLanguage = 33;
gxSimpChineseLanguage = 34;
gxFlemishLanguage = 35;
gxIrishLanguage = 36;
gxAlbanianLanguage = 37;
gxRomanianLanguage = 38;
gxCzechLanguage = 39;
gxSlovakLanguage = 40;
gxSlovenianLanguage = 41;
gxYiddishLanguage = 42;
gxSerbianLanguage = 43;
gxMacedonianLanguage = 44;
gxBulgarianLanguage = 45;
gxUkrainianLanguage = 46;
gxByelorussianLanguage = 47;
gxUzbekLanguage = 48;
gxKazakhLanguage = 49;
gxAzerbaijaniLanguage = 50;
gxAzerbaijanArLanguage = 51;
gxArmenianLanguage = 52;
gxGeorgianLanguage = 53;
gxMoldavianLanguage = 54;
gxKirghizLanguage = 55;
gxTajikiLanguage = 56;
gxTurkmenLanguage = 57;
gxMongolianLanguage = 58;
gxMongolianCyrLanguage = 59;
gxPashtoLanguage = 60;
gxKurdishLanguage = 61;
gxKashmiriLanguage = 62;
gxSindhiLanguage = 63;
gxTibetanLanguage = 64;
gxNepaliLanguage = 65;
gxSanskritLanguage = 66;
gxMarathiLanguage = 67;
gxBengaliLanguage = 68;
gxAssameseLanguage = 69;
gxGujaratiLanguage = 70;
gxPunjabiLanguage = 71;
gxOriyaLanguage = 72;
gxMalayalamLanguage = 73;
gxKannadaLanguage = 74;
gxTamilLanguage = 75;
gxTeluguLanguage = 76;
gxSinhaleseLanguage = 77;
gxBurmeseLanguage = 78;
gxKhmerLanguage = 79;
gxLaoLanguage = 80;
gxVietnameseLanguage = 81;
gxIndonesianLanguage = 82;
gxTagalogLanguage = 83;
gxMalayRomanLanguage = 84;
gxMalayArabicLanguage = 85;
gxAmharicLanguage = 86;
gxTigrinyaLanguage = 87;
gxGallaLanguage = 88;
gxOromoLanguage = gxGallaLanguage;
gxSomaliLanguage = 89;
gxSwahiliLanguage = 90;
gxRuandaLanguage = 91;
gxRundiLanguage = 92;
gxChewaLanguage = 93;
gxMalagasyLanguage = 94;
gxEsperantoLanguage = 95;
gxWelshLanguage = 129;
gxBasqueLanguage = 130;
gxCatalanLanguage = 131;
gxLatinLanguage = 132;
gxQuechuaLanguage = 133;
gxGuaraniLanguage = 134;
gxAymaraLanguage = 135;
gxTatarLanguage = 136;
gxUighurLanguage = 137;
gxDzongkhaLanguage = 138;
gxJavaneseRomLanguage = 139;
gxSundaneseRomLanguage = 140;
TYPE
gxFontLanguage = LONGINT;
CONST
gxCopyrightFontName = 1;
gxFamilyFontName = 2;
gxStyleFontName = 3;
gxUniqueFontName = 4;
gxFullFontName = 5;
gxVersionFontName = 6;
gxPostscriptFontName = 7;
gxTrademarkFontName = 8;
gxManufacturerFontName = 9;
gxLastReservedFontName = 256;
TYPE
gxFontName = LONGINT;
gxFontTableTag = LONGINT;
gxFontVariationTag = LONGINT;
gxFontFormatTag = LONGINT;
gxFontStorageTag = LONGINT;
gxFontDescriptorTag = gxFontVariationTag;
gxFontVariation = RECORD
name: gxFontVariationTag;
value: Fixed;
END;
gxFontDescriptor = gxFontVariation;
gxFontFeatureSetting = RECORD
setting: INTEGER;
nameID: INTEGER;
END;
CONST
gxSystemFontAttribute = $0001;
gxReadOnlyFontAttribute = $0002;
TYPE
gxFontAttribute = LONGINT;
CONST
gxMutuallyExclusiveFeature = $00008000;
TYPE
gxFontFeatureFlag = LONGINT;
gxFontFeature = LONGINT;
CONST
gxResourceFontStorage = 'rsrc';
gxHandleFontStorage = 'hndl';
gxFileFontStorage = 'bass';
gxNfntFontStorage = 'nfnt';
TYPE
gxFontStorageReference = Ptr;
{$SETC layoutTypesIncludes := 1}
gxGlyphcode = INTEGER;
{ single glyph in a font }
{ byte offset within backing store }
gxByteOffset = LONGINT;
{ The actual constants for feature types and selectors have been moved to a library. }
gxRunFeatureType = INTEGER;
gxRunFeatureSelector = INTEGER;
{ If tracking is not desired, specify the following value in the track field in the
gxRunControls record (note that a track of 0 does *not* mean to turn tracking off;
rather, it means to use normal tracking). }
CONST
gxNoTracking = $80000000;
{ The special "gxNoStake" value is returned by the GXGetLayoutBreakOffset call to
indicate the absence of a character offset that is stable with respect to
metamorphosis and contextual kerning. }
gxNoStake = -1;
{ A glyph's behavior with respect to other glyphs on its line is defined in part by its
gxBaselineType. These types allow correct alignment of the baselines of all glyphs on
the line. }
gxRomanBaseline = 0;
gxIdeographicCenterBaseline = 1;
gxIdeographicLowBaseline = 2;
gxHangingBaseline = 3;
gxMathBaseline = 4;
gxLastBaseline = 31;
gxNumberOfBaselineTypes = 32;
gxNoOverrideBaseline = 255;
TYPE
gxBaselineType = LONGINT;
gxBaselineDeltas = ARRAY [0..31] OF Fixed;
{ gxJustificationPriority defines the point during the justification process at which a
glyph will begin to receive deltas before and after itself. }
CONST
gxKashidaPriority = 0;
gxWhiteSpacePriority = 1;
gxInterCharPriority = 2;
gxNullJustificationPriority = 3;
gxNumberOfJustificationPriorities = 4;
TYPE
gxJustificationPriority = CHAR;
{ gxJustificationFlags are used to control which fields of a gxWidthDeltaRecord are to
be overridden and which are not if a gxPriorityJustificationOverride or
gxGlyphJustificationOverride (qq.v.) is specified. }
CONST
gxOverridePriority = $8000; { use priority value from override }
gxOverrideLimits = $4000; { use limits values from override }
gxOverrideUnlimited = $2000; { use unlimited flag from override }
gxUnlimitedGapAbsorption = $1000; { glyph can take unlimited gap }
gxJustificationPriorityMask = $000F; { justification priority }
gxAllJustificationFlags = $F00F;
TYPE
gxJustificationFlags = INTEGER;
{ The directional behavior of a glyph can be overridden using a gxDirectionOverride. }
CONST
gxNoDirectionOverride = 0;
gxImposeLeftToRight = 1;
gxImposeRightToLeft = 2;
gxImposeArabic = 3;
TYPE
gxDirectionOverride = INTEGER;
{ gxRunControlFlags describe the nonparametric layout options contained in a gxStyle. }
CONST
gxNoLigatureSplits = $80000000;
gxNoCaretAngle = $40000000;
gxImposeWidth = $20000000;
gxNoCrossKerning = $10000000;
gxNoOpticalAlignment = $08000000;
gxForceHanging = $04000000;
gxNoSpecialJustification = $02000000;
gxDirectionOverrideMask = $00000003;
gxAllRunControlFlags = $FE000003;
TYPE
gxRunControlFlags = LONGINT;
{ gxHighlightType is used to distinguish various highlighting methods, both in terms of
character offset based vs. visual based, and in terms of angled sides vs. non-angled
sides. }
CONST
gxHighlightStraight = 0; { straight-edged simple highlighting }
gxHighlightAverageAngle = 1; { takes average of two edge angles }
TYPE
gxHighlightType = LONGINT;
{ gxCaretType is used to control whether the caret that is returned from GXGetLayoutCaret
is a split caret or a (keyboard-syncronized) single caret. }
CONST
gxSplitCaretType = 0; { returns Mac-style split caret (default) }
gxLeftRightKeyboardCaret = 1; { single caret in left-right position }
gxRightLeftKeyboardCaret = 2; { single caret in right-left position }
TYPE
gxCaretType = LONGINT;
{ gxLayoutOffsetState describes the characteristics of a given gxByteOffset in some
layout. It is returned by the GXGetOffsetGlyphs call. Note that the
gxOffsetInsideLigature value is returned in addition to the 8/16 (or invalid)
indication. }
CONST
gxOffset8_8 = 0;
gxOffset8_16 = 1;
gxOffset16_8 = 2;
gxOffset16_16 = 3;
gxOffsetInvalid = 4;
gxOffsetInsideLigature = $8000;
TYPE
gxLayoutOffsetState = INTEGER;
{ gxLayoutOptionsFlags are single-bit flags contained in a gxLayoutOptions record. We
also define here some utility constants that are useful in setting various fields in
the gxLayoutOptions record. }
CONST
gxNoLayoutOptions = 0;
gxLineIsDisplayOnly = $00000001;
gxAllLayoutOptionsFlags = gxLineIsDisplayOnly;
gxMaxRunLevel = 15;
gxFlushLeft = 0;
gxFlushCenter = $20000000;
gxFlushRight = $40000000;
gxNoJustification = 0;
gxFullJustification = $40000000;
TYPE
gxLayoutOptionsFlags = LONGINT;
{ A gxRunFeature describes a feature and a level for that feature. }
gxRunFeature = RECORD
featureType: gxRunFeatureType;
featureSelector: gxRunFeatureSelector;
END;
{ A gxWidthDeltaRecord contains all of the information needed to describe the behavior of one
class of glyphs during the justification process. }
gxWidthDeltaRecord = RECORD
beforeGrowLimit: Fixed; { ems AW can grow by at most on LT }
beforeShrinkLimit: Fixed; { ems AW can shrink by at most on LT }
afterGrowLimit: Fixed; { ems AW can grow by at most on RB }
afterShrinkLimit: Fixed; { ems AW can shrink by at most on RB }
growFlags: gxJustificationFlags; { flags controlling grow case }
shrinkFlags: gxJustificationFlags; { flags controlling shrink case }
END;
{ A gxPriorityJustificationOverride contains an array of WidthDeltaRecords, one for each
gxJustificationPriority. }
gxPriorityJustificationOverride = RECORD
deltas: ARRAY [0..3] OF gxWidthDeltaRecord; { overrides for each of the priorities }
END;
{ A gxGlyphJustificationOverride contains a gxWidthDeltaRecord that is to be used for a
specific glyph in a specific run (this limitation is because glyphcodes vary by font). }
gxGlyphJustificationOverride = RECORD
glyph: gxGlyphcode;
override: gxWidthDeltaRecord;
END;
{ gxRunControls contains flags, shifts, imposed widths and overrides for a run. }
{ NOTE: a value of "gxNoTracking" (see above) in track disables tracking }
gxRunControls = RECORD
flags: gxRunControlFlags;
beforeWithStreamShift: Fixed;
afterWithStreamShift: Fixed;
crossStreamShift: Fixed;
imposedWidth: Fixed;
track: Fixed;
hangingInhibitFactor: Fract;
kerningInhibitFactor: Fract;
decompositionAdjustmentFactor: Fixed;
baselineType: gxBaselineType;
END;
{ A gxGlyphSubstitution describes one client-provided substitution that occurs after all
other automatic glyph changes have happened. }
gxGlyphSubstitution = RECORD
originalGlyph: gxGlyphcode; { Whenever you see this glyph... }
substituteGlyph: gxGlyphcode; { ...change it to this one. }
END;
{ gxKerningAdjustmentFactors specify an adjustment to automatic kerning. The adjustment
is ax + b where x is the automatic kerning value, a is scaleFactor, and b is
adjustmentPointSizeFactor times the run's point size. }
gxKerningAdjustmentFactors = RECORD
scaleFactor: Fract;
adjustmentPointSizeFactor: Fixed;
END;
{ A gxKerningAdjustment identifies with- and cross-stream kerning adjustments
for specific glyph pairs. }
gxKerningAdjustment = RECORD
firstGlyph: gxGlyphcode;
secondGlyph: gxGlyphcode;
withStreamFactors: gxKerningAdjustmentFactors;
crossStreamFactors: gxKerningAdjustmentFactors;
END;
{ A value of gxResetCrossStreamFactor in crossStreamFactors.adjustmentPointSizeFactor
will reset the cross-stream kerning to the baseline. }
CONST
gxResetCrossStreamFactor = $80000000;
{ gxLayoutHitInfo contains the output from the GXHitTestLayout call. }
TYPE
gxLayoutHitInfo = RECORD
firstPartialDist: Fixed;
lastPartialDist: Fixed;
hitSideOffset: gxByteOffset;
nonHitSideOffset: gxByteOffset;
leadingEdge: BOOLEAN;
inLoose: BOOLEAN;
END;
{ A gxLineBaselineRecord contains the deltas from 0 to all the different baselines for
the layout. It can be filled via a call to GetBaselineDeltas (q.v.). }
gxLineBaselineRecord = RECORD
deltas: gxBaselineDeltas;
END;
{ The gxLayoutOptions type contains information about the layout characteristics of the
whole line. }
gxLayoutOptions = RECORD
width: Fixed;
flush: Fract;
just: Fract;
flags: gxLayoutOptionsFlags;
baselineRec: ^gxLineBaselineRecord;
END;
{$SETC graphicsStreamTypesIncludes := 1}
CONST
gxNewObjectOpcode = $00; { create new object }
gxSetDataOpcode = $40; { add reference to current object }
gxSetDefaultOpcode = $80; { replace current default with this object }
gxReservedOpcode = $C0; { (may be used in future expansion) }
gxNextOpcode = $FF; { used by currentOperand field to say opcode is coming }
{ new object types (new object opcode) }
gxHeaderTypeOpcode = $00; { byte following new object uses bottom 6 bits for type }
{ gxShape types use values 1 (gxEmptyType) through 13 (gxPictureType) }
gxStyleTypeOpcode = $28;
gxInkTypeOpcode = $29;
gxTransformTypeOpcode = $2A;
gxColorProfileTypeOpcode = $2B;
gxColorSetTypeOpcode = $2C;
gxTagTypeOpcode = $2D;
gxBitImageOpcode = $2E;
gxFontNameTypeOpcode = $2F;
gxTrailerTypeOpcode = $3F;
{ fields of objects (set data opcodes) }
gxShapeAttributesOpcode = 0;
gxShapeTagOpcode = 1;
gxShapeFillOpcode = 2;
gxOmitPathPositionXMask = $C0;
gxOmitPathPositionYMask = $30;
gxOmitPathDeltaXMask = $0C;
gxOmitPathDeltaYMask = $03;
gxOmitPathPositionXShift = 6;
gxOmitPathPositionYShift = 4;
gxOmitPathDeltaXShift = 2;
gxOmitPathDeltaYShift = 0;
gxOmitBitmapImageMask = $C0;
gxOmitBitmapWidthMask = $30;
gxOmitBitmapHeightMask = $0C;
gxOmitBitmapRowBytesMask = $03;
gxOmitBitmapImageShift = 6;
gxOmitBitmapWidthShift = 4;
gxOmitBitmapHeightShift = 2;
gxOmitBitmapRowBytesShift = 0;
gxOmitBitmapPixelSizeMask = $C0;
gxOmitBitmapSpaceMask = $30;
gxOmitBitmapSetMask = $0C;
gxOmitBitmapProfileMask = $03;
gxOmitBitmapPixelSizeShift = 6;
gxOmitBitmapSpaceShift = 4;
gxOmitBitmapSetShift = 2;
gxOmitBitmapProfileShift = 0;
gxOmitBitmapPositionXMask = $C0;
gxOmitBitmapPositionYMask = $30;
gxOmitBitmapPositionXShift = 6;
gxOmitBitmapPositionYShift = 4;
gxOmitBitImageRowBytesMask = $C0;
gxOmitBitImageHeightMask = $30;
gxOmitBitImageDataMask = $08;
gxOmitBitImageRowBytesShift = 6;
gxOmitBitImageHeightShift = 4;
gxOmitBitImageDataShift = 3;
gxCopyBitImageBytesOpcode = $00;
gxRepeatBitImageBytesOpcode = $40;
gxLookupBitImageBytesOpcode = $80;
gxRepeatBitImageScanOpcode = $C0;
gxOmitTextCharactersMask = $C0;
gxOmitTextPositionXMask = $30;
gxOmitTextPositionYMask = $0C;
gxOmitTextDataMask = $02;
gxOmitTextCharactersShift = 6;
gxOmitTextPositionXShift = 4;
gxOmitTextPositionYShift = 2;
gxOmitTextDataShift = 1;
gxOmitGlyphCharactersMask = $C0;
gxOmitGlyphLengthMask = $30;
gxOmitGlyphRunNumberMask = $0C;
gxOmitGlyphOnePositionMask = $02;
gxOmitGlyphDataMask = $01;
gxOmitGlyphCharactersShift = 6;
gxOmitGlyphLengthShift = 4;
gxOmitGlyphRunNumberShift = 2;
gxOmitGlyphOnePositionShift = 1;
gxOmitGlyphDataShift = 0;
gxOmitGlyphPositionsMask = $C0;
gxOmitGlyphAdvancesMask = $20;
gxOmitGlyphTangentsMask = $18;
gxOmitGlyphRunsMask = $04;
gxOmitGlyphStylesMask = $03;
gxOmitGlyphPositionsShift = 6;
gxOmitGlyphAdvancesShift = 5;
gxOmitGlyphTangentsShift = 3;
gxOmitGlyphRunsShift = 2;
gxOmitGlyphStylesShift = 0;
gxOmitLayoutLengthMask = $C0;
gxOmitLayoutPositionXMask = $30;
gxOmitLayoutPositionYMask = $0C;
gxOmitLayoutDataMask = $02;
gxOmitLayoutLengthShift = 6;
gxOmitLayoutPositionXShift = 4;
gxOmitLayoutPositionYShift = 2;
gxOmitLayoutDataShift = 1;
gxOmitLayoutWidthMask = $C0;
gxOmitLayoutFlushMask = $30;
gxOmitLayoutJustMask = $0C;
gxOmitLayoutOptionsMask = $03;
gxOmitLayoutWidthShift = 6;
gxOmitLayoutFlushShift = 4;
gxOmitLayoutJustShift = 2;
gxOmitLayoutOptionsShift = 0;
gxOmitLayoutStyleRunNumberMask = $C0;
gxOmitLayoutLevelRunNumberMask = $30;
gxOmitLayoutHasBaselineMask = $08;
gxOmitLayoutStyleRunsMask = $04;
gxOmitLayoutStylesMask = $03;
gxOmitLayoutStyleRunNumberShift = 6;
gxOmitLayoutLevelRunNumberShift = 4;
gxOmitLayoutHasBaselineShift = 3;
gxOmitLayoutStyleRunsShift = 2;
gxOmitLayoutStylesShift = 0;
gxOmitLayoutLevelRunsMask = $80;
gxOmitLayoutLevelsMask = $40;
gxOmitLayoutLevelRunsShift = 7;
gxOmitLayoutLevelsShift = 6;
gxInkAttributesOpcode = 0;
gxInkTagOpcode = 1;
gxInkColorOpcode = 2;
gxInkTransferModeOpcode = 3;
gxOmitColorsSpaceMask = $C0;
gxOmitColorsProfileMask = $30;
gxOmitColorsComponentsMask = $0F;
gxOmitColorsIndexMask = $0C;
gxOmitColorsIndexSetMask = $03;
gxOmitColorsSpaceShift = 6;
gxOmitColorsProfileShift = 4;
gxOmitColorsComponentsShift = 0;
gxOmitColorsIndexShift = 2;
gxOmitColorsIndexSetShift = 0;
gxOmitTransferSpaceMask = $C0;
gxOmitTransferSetMask = $30;
gxOmitTransferProfileMask = $0C;
gxOmitTransferSpaceShift = 6;
gxOmitTransferSetShift = 4;
gxOmitTransferProfileShift = 2;
gxOmitTransferSourceMatrixMask = $C0;
gxOmitTransferDeviceMatrixMask = $30;
gxOmitTransferResultMatrixMask = $0C;
gxOmitTransferFlagsMask = $03;
gxOmitTransferSourceMatrixShift = 6;
gxOmitTransferDeviceMatrixShift = 4;
gxOmitTransferResultMatrixShift = 2;
gxOmitTransferFlagsShift = 0;
gxOmitTransferComponentModeMask = $80;
gxOmitTransferComponentFlagsMask = $40;
gxOmitTransferComponentSourceMinimumMask = $30;
gxOmitTransferComponentSourceMaximumMask = $0C;
gxOmitTransferComponentDeviceMinimumMask = $03;
gxOmitTransferComponentModeShift = 7;
gxOmitTransferComponentFlagsShift = 6;
gxOmitTransferComponentSourceMinimumShift = 4;
gxOmitTransferComponentSourceMaximumShift = 2;
gxOmitTransferComponentDeviceMinimumShift = 0;
gxOmitTransferComponentDeviceMaximumMask = $C0;
gxOmitTransferComponentClampMinimumMask = $30;
gxOmitTransferComponentClampMaximumMask = $0C;
gxOmitTransferComponentOperandMask = $03;
gxOmitTransferComponentDeviceMaximumShift = 6;
gxOmitTransferComponentClampMinimumShift = 4;
gxOmitTransferComponentClampMaximumShift = 2;
gxOmitTransferComponentOperandShift = 0;
gxStyleAttributesOpcode = 0;
gxStyleTagOpcode = 1;
gxStyleCurveErrorOpcode = 2;
gxStylePenOpcode = 3;
gxStyleJoinOpcode = 4;
gxStyleDashOpcode = 5;
gxStyleCapsOpcode = 6;
gxStylePatternOpcode = 7;
gxStyleTextAttributesOpcode = 8;
gxStyleTextSizeOpcode = 9;
gxStyleFontOpcode = 10;
gxStyleTextFaceOpcode = 11;
gxStylePlatformOpcode = 12;
gxStyleFontVariationsOpcode = 13;
gxStyleRunControlsOpcode = 14;
gxStyleRunPriorityJustOverrideOpcode = 15;
gxStyleRunGlyphJustOverridesOpcode = 16;
gxStyleRunGlyphSubstitutionsOpcode = 17;
gxStyleRunFeaturesOpcode = 18;
gxStyleRunKerningAdjustmentsOpcode = 19;
gxStyleJustificationOpcode = 20;
gxOmitDashAttributesMask = $C0;
gxOmitDashShapeMask = $30;
gxOmitDashAdvanceMask = $0C;
gxOmitDashPhaseMask = $03;
gxOmitDashAttributesShift = 6;
gxOmitDashShapeShift = 4;
gxOmitDashAdvanceShift = 2;
gxOmitDashPhaseShift = 0;
gxOmitDashScaleMask = $C0;
gxOmitDashScaleShift = 6;
gxOmitPatternAttributesMask = $C0;
gxOmitPatternShapeMask = $30;
gxOmitPatternUXMask = $0C;
gxOmitPatternUYMask = $03;
gxOmitPatternAttributesShift = 6;
gxOmitPatternShapeShift = 4;
gxOmitPatternUXShift = 2;
gxOmitPatternUYShift = 0;
gxOmitPatternVXMask = $C0;
gxOmitPatternVYMask = $30;
gxOmitPatternVXShift = 6;
gxOmitPatternVYShift = 4;
gxOmitJoinAttributesMask = $C0;
gxOmitJoinShapeMask = $30;
gxOmitJoinMiterMask = $0C;
gxOmitJoinAttributesShift = 6;
gxOmitJoinShapeShift = 4;
gxOmitJoinMiterShift = 2;
gxOmitCapAttributesMask = $C0;
gxOmitCapStartShapeMask = $30;
gxOmitCapEndShapeMask = $0C;
gxOmitCapAttributesShift = 6;
gxOmitCapStartShapeShift = 4;
gxOmitCapEndShapeShift = 2;
gxOmitFaceLayersMask = $C0;
gxOmitFaceMappingMask = $30;
gxOmitFaceLayersShift = 6;
gxOmitFaceMappingShift = 4;
gxOmitFaceLayerFillMask = $C0;
gxOmitFaceLayerFlagsMask = $30;
gxOmitFaceLayerStyleMask = $0C;
gxOmitFaceLayerTransformMask = $03;
gxOmitFaceLayerFillShift = 6;
gxOmitFaceLayerFlagsShift = 4;
gxOmitFaceLayerStyleShift = 2;
gxOmitFaceLayerTransformShift = 0;
gxOmitFaceLayerBoldXMask = $C0;
gxOmitFaceLayerBoldYMask = $30;
gxOmitFaceLayerBoldXShift = 6;
gxOmitFaceLayerBoldYShift = 4;
gxColorSetReservedOpcode = 0;
gxColorSetTagOpcode = 1;
gxColorProfileReservedOpcode = 0;
gxColorProfileTagOpcode = 1;
gxTransformReservedOpcode = 0;
gxTransformTagOpcode = 1;
gxTransformClipOpcode = 2;
gxTransformMappingOpcode = 3;
gxTransformPartMaskOpcode = 4;
gxTransformToleranceOpcode = 5;
gxTypeOpcode = 0;
gxSizeOpcode = 1;
{ used by currentOperand when currentOperation is gxNextOpcode }
{ format of top byte:
xx yyyyyy xx == 0x00, 0x40, 0x80, 0xC0: defines graphics operation (see gxGraphicsOperationOpcode)
yyyyyy == size of operation in bytes
if (yyyyyy == 0), byte size follows. If byte following == 0, word size follows; if == 0, long follows
word and long, if present, are specified in high-endian order (first byte is largest magnitude)
format of byte following size specifiers, if any:
xx yyyyyy xx == 0x00, 0x40, 0x80, 0xC0: defines compression level (0 == none, 0xC0 == most)
exact method of compression is defined by type of data
yyyyyy == data type selector (0 to 63): see gxGraphicsNewOpcode, __DataOpcode
}
gxOpcodeShift = 6;
gxObjectSizeMask = $3F;
gxCompressionShift = 6;
gxObjectTypeMask = $3F;
gxBitImageOpcodeMask = $C0;
gxBitImageCountMask = $3f;
gxBitImageOpcodeShift = 6;
gxNoCompression = 0;
gxWordCompression = 1;
gxByteCompression = 2;
gxOmitCompression = 3;
gxCompressionMask = $03;
{ the following structures define how primitives without a public geometry
are stored (their format mirrors that of the New call to create them) }
TYPE
gxFlatFontName = RECORD
name: SInt8; { unsigned char } { gxFontName }
platform: SInt8; { unsigned char } { gxFontPlatform }
script: SInt8; { unsigned char } { gxFontScript }
language: SInt8; { unsigned char } { gxFontLanguage }
length: INTEGER; { byte length }
END;
CONST
gxFlatFontListItemTag = 'flst';
TYPE
gxFlatFontListItem = RECORD
fontID: gxFont; {** if we get rid of this, remove #include "font types.h", above }
name: SInt8; { unsigned char } { gxFontName }
platform: SInt8; { unsigned char } { gxFontPlatform }
script: SInt8; { unsigned char } { gxFontScript }
language: SInt8; { unsigned char } { gxFontLanguage }
length: INTEGER; { byte length of the name that follows }
glyphCount: INTEGER; { CountFontGlyphs or 0 if gxFontGlyphsFlatten is false }
axisCount: INTEGER; { CountFontVariations or 0 if gxFontVariationsFlatten is false }
variationCount: INTEGER; { number of bitsVariationPairs that follow the (optional) glyphBits }
END;
gxFlatFontList = RECORD
count: LONGINT;
items: ARRAY [0..0] OF gxFlatFontListItem;
END;
gxFlattenHeader = RECORD
version: Fixed;
flatFlags: SInt8; { unsigned char }
padding: SInt8;
END;
CONST
gxOmitPictureShapeMask = $C0;
gxOmitOverrideStyleMask = $30;
gxOmitOverrideInkMask = $0C;
gxOmitOverrideTransformMask = $03;
gxOmitPictureShapeShift = $6;
gxOmitOverrideStyleShift = $4;
gxOmitOverrideInkShift = $2;
gxOmitOverrideTransformShift = $0;
{$SETC gxSynonymTags := 1}
gxPostScriptTag = 'post';
gxPostControlTag = 'psct';
gxNoSave = 1; { don't do save-restore around PS data }
gxPSContinueNext = 2; { next shape is continuation of this shape's PS -- only obeyed if gxNoSave is true }
TYPE
gxPostControl = RECORD
flags: LONGINT; { PostScript state flags }
END;
CONST
gxDashSynonymTag = 'sdsh';
TYPE
gxDashSynonym = RECORD
size: LONGINT; { number of elements in array }
dashLength: ARRAY [0..0] OF Fixed; { Array of dash lengths }
END;
CONST
gxLineCapSynonymTag = 'lcap';
gxButtCap = 0;
gxRoundCap = 1;
gxSquareCap = 2;
gxTriangleCap = 3;
{ gxLine cap type }
TYPE
gxLineCapSynonym = LONGINT;
CONST
gxCubicSynonymTag = 'cubx';
gxIgnoreFlag = $0000; { Ignore this word, get next one }
gxLineToFlag = $0001; { Draw a gxLine to gxPoint following this flag }
gxCurveToFlag = $0002; { Draw a gxCurve through the 3 points following this flag }
gxMoveToFlag = $0003; { Start a new contour at the gxPoint following this flag }
gxClosePathFlag = $0004; { Close the contour }
gxCubicInstructionMask = $000F; { low four bits are gxPoint instructions }
{ Low four bits are instruction (moveto, lineto, curveto, closepath) }
TYPE
gxCubicSynonymFlags = INTEGER;
CONST
gxPatternSynonymTag = 'ptrn';
gxHatch = 0;
gxCrossHatch = 1;
TYPE
gxPatternSynonym = RECORD
patternType: LONGINT; { one of the gxPatterns: gxHatch or gxCrossHatch }
angle: Fixed; { angle at which pattern is drawn }
spacing: Fixed; { distance between two parallel pattern lines }
thickness: Fixed; { thickness of the pattern }
anchorPoint: gxPoint; { gxPoint with with respect to which pattern position is calculated }
END;
{ $ALIGN RESET}
{ $POP}
{$ENDC} {__GXTYPES__}
IMPLEMENTATION
END.